package com.eslserver.core.config;

import java.util.HashMap;
import java.util.List;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.w3c.dom.Element;

import com.eslserver.util.XMLConfigUtil;

public class HTTPServerConfig {
	static final Logger LOG = LoggerFactory.getLogger(HTTPServerConfig.class);

	public static String name;
	public static String urlPath;

	public void readHTTPServerSourcesFromXml(Element e) {
		List<Element> n = XMLConfigUtil.getChildNodes(e,
				ESLServerConfig.STITEQ_HTTP_SERVER);
		if (!n.isEmpty()) {
			for (Element element : n) {
				HashMap<String, String> attrs = XMLConfigUtil
						.getAllAttributes(element);
				name = attrs.get("name");
				urlPath = attrs.get("url");
			}
		}
	}
}
